<%@ page language="java" contentType="text/html; charset=UTF-8"%>
<%@include file="/pageRc/common/common.jsp"%>

<!DOCTYPE html>
<html lang="en" style="overflow-x: hidden">
<head>
<meta charset="UTF-8">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport"
	content="initial-scale=1.0,maximum-scale=1.0,user-scalable=no">
<meta name="format-detection" content="telephone=no">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="mobile-web-app-capable" content="yes">
<meta name="msapplication-tap-highlight" content="no">

<link rel="stylesheet" href="<%=commonPath %>/pageRc/layui/css/layui.css" media="all">
<link rel="stylesheet" href="<%=commonPath %>/pageRc/css/manlogin/admin.css" media="all">
<link rel="stylesheet" href="<%=commonPath %>/pageRc/css/manlogin/login.css" media="all">
<link id="layuicss-layer" rel="stylesheet" href="<%=commonPath %>/pageRc/css/manlogin/layer.css" media="all">
<link rel="stylesheet" href="<%=commonPath %>/pageRc/css/manlogin/layui.css" media="all">
<script type="text/javascript" src="<%=commonPath %>/pageRc/js/jquery-1.9.1.min.js"></script> 
<script type="text/javascript" src="<%=commonPath %>/pageRc/layui/layui.js"></script>
<script type="text/javascript" src="<%=commonPath %>/pageRc/common/utils.js"></script>
<script type="text/javascript" src="<%=commonPath %>/pageRc/common/msgTool.js"></script>

<title>确认密码</title>
<style type="text/css">
.layui-main{
   width: 300px;
}
</style>
<script>
$(function(){
	
})
var path="<%=commonPath%>";
var msg = new msgTool();
layui.use(
		[ 'form', 'layer', 'laytpl', 'laypage','laydate' ],
		function() {
			var $ = layui.jquery, layer = layui.layer; //独立版的layer无需执行这一句
	        var form = layui.form()
	            ,layer = layui.layer
	            ,laypage = layui.laypage
	            ,laytpl = layui.laytpl; 
		
	       
		});
	function confirm(){
		var oldPwd = $("#oldPwd").val();   
	if(oldPwd!="")	{
		var phoneNo = $("#phoneNo").val();
		
		$.ajax({
			url : "<%=commonPath%>/page/sys/adminLogin.do",
			data : {"phoneNo":phoneNo,"password":oldPwd},
			type : "post",
			dataType : "json",
			success : function(data) {
				if(data.head.retMsg == "success"){
					//window.location.href = window.location.href;
					location.href ="<%=commonPath%>/page/sys/18PW/report.do";
				}
				if(data.head.retMsg =="手机号码或者密码不正确。"){
						alert("密码错误!");
				}
			}
		});
		
		

	  } 
	
	
	}
	

</script>
</head>
<body class="layui-main">

<input type="hidden" id="phoneNo" value="${phoneNo}">

     <!--修改密码-->
    	<div class="layadmin-user-login-main">
			<div class="layadmin-user-login-box layadmin-user-login-header">
				<h2>确认密码</h2>
			</div>
			<div
				class="layadmin-user-login-box layadmin-user-login-body layui-form">
				<div class="layui-form-item">
					<label
						class="layadmin-user-login-icon layui-icon layui-icon-form"
						for="LAY-user-login-username"></label> <input type="password"
						name="oldPwd" id="oldPwd" lay-verify="required"
						placeholder="登录密码" class="layui-input">
				</div>
				
				<div class="layui-form-item">
					<button class="layui-btn layui-btn-fluid" lay-submit=""
						lay-filter="LAY-user-login-submit" onclick="confirm()">确认</button>
				</div>
			</div>
		</div>

</body>

</html>